Repository navigation
Conversation
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Move/Copy on a component drew its triad on a painter layer of its own. egui only finds the layer under the pointer among its areas, so that layer was never under it: the arrows never lit up and a drag went to the view instead. The triad is now drawn by the viewport with the Move window's, and the viewport leaves a press on it to the triad. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
phanoob
marked this pull request as ready for review
October 19, 2026 20:22
Contributor
Author
|
Closing: #3015 (merged for #3014) fixed the same thing on main, drawing the occurrence triad in the viewport. This PR's harness test (dragging the X arrow of Move/Copy on an occurrence moves it, not the camera) passes against main's code as it is, so #3203 should be fixed by #3015 too. 🤖 Generated with Claude Code |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #3203.
Problem
Move/Copy from a component's right-click menu opens the Move: window and draws a move triad. An inserted STEP file is such a component. Its arrows never lit up, and dragging them did nothing: the drag went to the view. Typed distances worked.
The cause: that triad was painted on an egui layer of its own (
LayerId::new(Order::Middle, …)with no area behind it). egui only looks among its areas for the layer under the pointer, so for that layer the answer was always "not this one".gizmo::showsaw no pointer over its rectangle, found no handle hovered, and never started a drag.This was not specific to STEP. Native geometry most likely worked for the reporter because it went through the Move window (M on bodies), whose triad the viewport draws.
Fix
canvas::show, next to the Move window's triad:browser::occurrence_move_triad.canvas::owns_pointernow includes the occurrence triad, so navigation leaves a press on its handles to the triad.occurrence.moveonly when a value changed.Steps: make a box and a cylinder,
file.exportto a STEP file, start a new design,file.insert_stepit, right-click the component, choose Move/Copy, then drag the red arrow.Tests
browser::occurrence_ui_tests::dragging_the_occurrence_triad_moves_the_occurrence(harness): opens Move/Copy on an occurrence and drags its X arrow. The test checks three things:It fails on main with a translation of
[0, 0, 0].cargo clippy -p solidcraft-ui-egui --all-targets -D warningsis clean.The browser, occurrence, canvas, Move dialog, gizmo, navigation and viewport tests pass, except
expression_complete::…modified_navigation…andviewport::…visible_gaps. Those two also fail on main on this Windows machine.🤖 Generated with Claude Code